package com.woniuxy.uumsserver.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 
 * @TableName finance_addr
 */
@TableName(value ="finance_addr")
@Data
public class FinanceAddr implements Serializable {
    /**
     * 主键
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 收货地址
     */
    private String financeAddr;

    /**
     * 用户id
     */
    private Long financeUserId;

    /**
     * 联系人
     */
    private String financeLinkman;

    /**
     * 联系电话
     */
    private String financePhone;

    /**
     * 0：注销，1：正常
     */
    private Integer financeState;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 创建人
     */
    private String createBy;

    /**
     * 修改时间
     */
    private Date updateTime;

    /**
     * 修改人
     */
    private String updateBy;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        FinanceAddr other = (FinanceAddr) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getFinanceAddr() == null ? other.getFinanceAddr() == null : this.getFinanceAddr().equals(other.getFinanceAddr()))
            && (this.getFinanceUserId() == null ? other.getFinanceUserId() == null : this.getFinanceUserId().equals(other.getFinanceUserId()))
            && (this.getFinanceLinkman() == null ? other.getFinanceLinkman() == null : this.getFinanceLinkman().equals(other.getFinanceLinkman()))
            && (this.getFinancePhone() == null ? other.getFinancePhone() == null : this.getFinancePhone().equals(other.getFinancePhone()))
            && (this.getFinanceState() == null ? other.getFinanceState() == null : this.getFinanceState().equals(other.getFinanceState()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getFinanceAddr() == null) ? 0 : getFinanceAddr().hashCode());
        result = prime * result + ((getFinanceUserId() == null) ? 0 : getFinanceUserId().hashCode());
        result = prime * result + ((getFinanceLinkman() == null) ? 0 : getFinanceLinkman().hashCode());
        result = prime * result + ((getFinancePhone() == null) ? 0 : getFinancePhone().hashCode());
        result = prime * result + ((getFinanceState() == null) ? 0 : getFinanceState().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", financeAddr=").append(financeAddr);
        sb.append(", financeUserId=").append(financeUserId);
        sb.append(", financeLinkman=").append(financeLinkman);
        sb.append(", financePhone=").append(financePhone);
        sb.append(", financeState=").append(financeState);
        sb.append(", createTime=").append(createTime);
        sb.append(", createBy=").append(createBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}